Skip to content

Update pybind11 requirement from >=2.10.0 to >=3.0.3#348

Closed
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/pip/pybind11-gte-3.0.3
Closed

Update pybind11 requirement from >=2.10.0 to >=3.0.3#348
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/pip/pybind11-gte-3.0.3

Conversation

@dependabot
Copy link
Copy Markdown
Contributor

@dependabot dependabot Bot commented on behalf of github Apr 14, 2026

Updates the requirements on pybind11 to permit the latest version.

Release notes

Sourced from pybind11's releases.

Version 3.0.3

Bug fixes:

  • Fixed TSS key exhaustion in implicitly_convertible() when many implicit conversions are registered across large module sets. #6020

  • Fixed heap-buffer-overflow in pythonbuf with undersized buffers by enforcing a minimum buffer size. #6019

  • Fixed virtual-inheritance pointer offset crashes when dispatching inherited methods through virtual bases. #6017

  • Fixed free(): invalid pointer crashes during interpreter shutdown with py::enum_<> by duplicating late-added def_property_static argument strings. #6015

  • Fixed function_record heap-type deallocation to call PyObject_Free() and decref the type. #6010

  • Hardened PYBIND11_MODULE_PYINIT and get_internals() against module-initialization crashes. #6018

  • Fixed static_pointer_cast build failure with virtual inheritance in holder_caster_foreign_helpers.h. #6014

  • Fixed ambiguous factory template specialization that caused compilation failures with nvcc + GCC 14. #6011

  • Fixed crash in def_readwrite for non-smart-holder properties of smart-holder classes. #6008

  • Fixed memory leak for py::dynamic_attr() objects on Python 3.13+ by clearing managed __dict__ contents during deallocation. #5999

  • Fixed binding of noexcept and ref-qualified (&, &&) methods inherited from unregistered base classes. #5992

Internal:

  • Moved tomlkit dependency to the dev dependency group. #5990

  • Switched to newer public CPython APIs (PyType_GetFlags and public vectorcall APIs where available). #6005

Tests:

  • Made an async callback test deterministic by replacing fixed sleep with bounded waiting. #5986

CI:

... (truncated)

Changelog

Sourced from pybind11's changelog.

Version 3.0.3 (March 31, 2026)

Bug fixes:

  • Fixed TSS key exhaustion in implicitly_convertible() when many implicit conversions are registered across large module sets. #6020

  • Fixed heap-buffer-overflow in pythonbuf with undersized buffers by enforcing a minimum buffer size. #6019

  • Fixed virtual-inheritance pointer offset crashes when dispatching inherited methods through virtual bases. #6017

  • Fixed free(): invalid pointer crashes during interpreter shutdown with py::enum_<> by duplicating late-added def_property_static argument strings. #6015

  • Fixed function_record heap-type deallocation to call PyObject_Free() and decref the type. #6010

  • Hardened PYBIND11_MODULE_PYINIT and get_internals() against module-initialization crashes. #6018

  • Fixed static_pointer_cast build failure with virtual inheritance in holder_caster_foreign_helpers.h. #6014

  • Fixed ambiguous factory template specialization that caused compilation failures with nvcc + GCC 14. #6011

  • Fixed crash in def_readwrite for non-smart-holder properties of smart-holder classes. #6008

  • Fixed memory leak for py::dynamic_attr() objects on Python 3.13+ by clearing managed __dict__ contents during deallocation. #5999

  • Fixed binding of noexcept and ref-qualified (&, &&) methods inherited from unregistered base classes. #5992

Internal:

  • Moved tomlkit dependency to the dev dependency group. #5990

  • Switched to newer public CPython APIs (PyType_GetFlags and public vectorcall APIs where available). #6005

Tests:

  • Made an async callback test deterministic by replacing fixed sleep with bounded waiting. #5986

... (truncated)

Commits
  • 1b49908 docs: add v3.0.3 and v3.1.0 changelog updates. (#6023)
  • c066c76 fix: add missing PYBIND11_ALWAYS_INLINE macro for v3.0.3 backports
  • 76efcb3 Bump version from v3.0.2 → v3.0.3
  • 0f41635 chore(deps): bump pygments from 2.17.2 to 2.20.0 in /docs (#6024)
  • 54a4615 chore(deps): bump requests from 2.32.4 to 2.33.0 in /docs (#6013)
  • d12037c chore(deps): update pre-commit hooks (#6002)
  • 64eecc4 chore(deps): bump the actions group with 3 updates (#6000)
  • c0ea8fc Fix heap-buffer-overflow in pythonbuf with undersized buffers (#6019)
  • 8d621d6 fix: detect virtual inheritance in add_base to prevent pointer offset crash (...
  • b6a616e fix: strdup "self" arg in def_property_static, partially revert #6010 (gh...
  • Additional commits viewable in compare view


Note

Low Risk
Low risk dependency bump limited to build configuration, though it could surface new C++ extension build/ABI incompatibilities in CI or downstream builds.

Overview
Updates pyproject.toml build-system requirements to raise the minimum pybind11 version from >=2.10.0 to >=3.0.3, allowing builds to use the latest pybind11 release.

Reviewed by Cursor Bugbot for commit b95bfad. Bugbot is set up for automated code reviews on this repo. Configure here.

@dependabot dependabot Bot added Changed Required label for PR that categorizes merge commit message as "Changed" for changelog dependencies Pull requests that update a dependency file python Pull requests that update Python code labels Apr 14, 2026
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 14, 2026

🤖 Cursor Dependency Analysis

Supply-Chain Malware Review

Checking how this repo declares the pybind11 dependency to ground the review.

Verdict: benign

Why this is not malware (concise):

  • Package identity: The change targets pybind11 on the official pybind/pybind11 project—standard C++/Python bindings, not a typosquat.
  • Scanner vs interpretation: The report is warn with 0 unicode, confusable, and IOC hits. The heuristic hits are false positives in context: shell_process_spawn matches py::exec and comments containing “exec” (Python C API, not exec(3)/shell). ghost_version_or_missing_tag and maintainer_drift look like tooling limits (e.g. semver range strings, or npm-oriented checks) rather than evidence of a fake package—pybind11 3.0.3 is a normal, documented release in upstream notes you pasted.
  • Checklist (classic obfuscation / exfil / persistence): No indicators in the described update: a minimum version bump in build metadata, release notes that are bugfix-heavy, and no reported hidden Unicode, obfuscated loaders, or unexpected install hooks for this Python dependency (this isn’t an npm package.json postinstall scenario).
  • Dependabot / scope: The scanner’s 21 files and .github/workflows/ touches appear to be from an upstream diff (pybind11 itself) in your scan config, not proof that your app repo PR edits workflows or node_modules. For review, still confirm the real PR only changes the intended manifest(s) (e.g. pyproject.toml build-system.requires); if it does, there is no supply-chain red flag.
  • Residual risk (not malware): Jumping the floor from 2.x to 3.x can need compatibility/CI validation (API SemVer), but that is an integration risk, not compromise.

Actionable follow-up: Merge is reasonable from a supply-chain perspective once the project diff is only the version constraint you expect and CI passes with pybind11 3.x.

Compatibility Analysis

Searching the repository for pybind11 usage and inspecting how it's declared and built.

1) Where pybind11 shows up

  • pyproject.toml — PEP 517 build dependency: requires = [..., "pybind11..."] (in this tree it is already >=3.0.3).
  • src/CMakeLists.txt — Resolves CMake pybind11 via python -m pybind11 --cmakedir + find_package(pybind11 CONFIG); if missing, FetchContent pulls a pinned git tag (currently v2.13.6) and then pybind11_add_module(...).
  • src/python_bindings/fastvdf.cpp — Only real application of the API: a single PYBIND11_MODULE and several m.def(...) lambdas using py::bytes, py::tuple / py::make_tuple, and py::gil_scoped_release.

There is no separate Python import pybind11 in application code; it is a build-time dependency for the extension.

2) Overlap with 3.0.3 / changed areas

  • Your bindings are only free functions: no py::class_, no py::enum_, no py::iostream / pythonbuf, no implicitly_convertible, no virtual / smart-holder patterns from the release notes.
  • 3.0.3 items like module init / get_internals() and general GIL / PYBIND11_MODULE plumbing are used by any module, but here that is the stock PYBIND11_MODULE pattern with no custom hooks — so the announced fixes are broadly beneficial and not tied to exotic APIs in this repo.

So: low direct “API break” risk for fastvdf.cpp as written; the jump is more “2.x → 3.x” in general than “these specific 3.0.3 fixes.”

3) Risks / unknowns

  • Major version (>=2.10.0>=3.0.3): anything not covered by a quick skim should be covered by CI (especially cibuildwheel / matrix) and a normal pytest run.
  • CMake vs pip mismatch: the FetchContent fallback still points at 2.13.6 while the PR raises the declared build requirement to 3.x. If find_package ever fails, you could build against 2.13.6 while metadata says ≥3.0.3 — worth aligning the fallback tag (or making find failure fatal) in a follow-up, not necessarily in this bot PR.
  • Downstream packagers building from source need a 3.x pybind11 in the build env (expected if they follow pyproject build deps).

4) Recommendation

merge-with-caveats

  • Merge if CI (wheel builds + tests) is green: the in-repo binding code is a small, stable surface, and 3.0.3 is bugfix-oriented on areas you do not use directly.
  • Caveat: treat green CI as the gate for the 2 → 3 line jump, and plan a small follow-up to reconcile CMake FetchContent with the new minimum version if you care about the offline / no-pybind11-wheel edge case.

Malware Scan Summary

  • Status: warn
  • Warn only mode: true
  • Changed upstream files scanned: 21
  • Resolution strategy: commit_list
  • Changed node/vendor paths: 0
  • Changed lockfiles: 0
  • Resolved refs: from=n/a to=n/a
  • Unicode findings (post-allowlist): 0
  • Confusable findings (post-allowlist): 0
  • IOC findings (post-allowlist): 0
  • Heuristic findings (post-allowlist): 12

Top findings

  • tests/test_with_catch/test_interpreter.cpp:117 shell_process_spawn :: py::exec(R"(
  • tests/test_with_catch/test_interpreter.cpp:167 shell_process_spawn :: py::exec(R"(
  • tests/test_with_catch/test_interpreter.cpp:375 shell_process_spawn :: // When the interpreter is embedded, there is no execution frame, but py::exec
  • tests/test_with_catch/test_interpreter.cpp:377 shell_process_spawn :: py::exec("var = dict(number=42)");
  • include/pybind11/pybind11.h:1578 shell_process_spawn :: /// Initialize an array of slots based on the supplied exec slot and options.
  • docs/changelog.md:2086 shell_process_spawn :: - py::exec, py::eval, and py::eval_file now add the builtins
  • docs/changelog.md:2088 shell_process_spawn :: matching exec and eval in pure Python.
  • docs/changelog.md:2774 shell_process_spawn :: - Added py::exec() as a shortcut for py::eval<py::eval_statements>()
  • .github/workflows/nightlies.yml:0 workflow_path_touch :: path-touch
  • .github/workflows/pip.yml:0 workflow_path_touch :: path-touch
  • pybind11:0 ghost_version_or_missing_tag :: >=3.0.3
  • pybind11:0 maintainer_drift :: >=2.10.0->>=3.0.3

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 0da4501. Configure here.

Comment thread pyproject.toml Outdated
@@ -1,5 +1,5 @@
[build-system]
requires = ["setuptools>=42", "wheel", "setuptools_scm[toml]>=3.5.0", "pybind11>=2.10.0"]
requires = ["setuptools>=42", "wheel", "setuptools_scm[toml]>=3.5.0", "pybind11>=3.0.3"]
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CMake fallback fetches outdated pybind11 v2.13.6 version

Medium Severity

The pyproject.toml build requirement now mandates pybind11>=3.0.3, but src/CMakeLists.txt line 244 has a FetchContent_Declare fallback pinned to GIT_TAG v2.13.6. If CMake can't find the pip-installed pybind11 (e.g., in certain CI or from-source builds), the fallback fetches a 2.x version that's incompatible with the 3.x minimum. This version mismatch can lead to build failures or subtle ABI incompatibilities since pybind11 3.0 is a major version with breaking changes.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 0da4501. Configure here.

Updates the requirements on [pybind11](https://github.com/pybind/pybind11) to permit the latest version.
- [Release notes](https://github.com/pybind/pybind11/releases)
- [Changelog](https://github.com/pybind/pybind11/blob/master/docs/changelog.md)
- [Commits](pybind/pybind11@v2.10.0...v3.0.3)

---
updated-dependencies:
- dependency-name: pybind11
  dependency-version: 3.0.3
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot force-pushed the dependabot/pip/pybind11-gte-3.0.3 branch from 0da4501 to b95bfad Compare April 22, 2026 15:19
@dependabot @github
Copy link
Copy Markdown
Contributor Author

dependabot Bot commented on behalf of github Apr 28, 2026

Superseded by #353.

@dependabot dependabot Bot closed this Apr 28, 2026
@dependabot dependabot Bot deleted the dependabot/pip/pybind11-gte-3.0.3 branch April 28, 2026 17:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Changed Required label for PR that categorizes merge commit message as "Changed" for changelog dependencies Pull requests that update a dependency file python Pull requests that update Python code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants